<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html><head><script type="text/javascript" src="https://cdn.jsdelivr.net/gh/opencobra/cobratoolbox@ffa0229fc0c01c9236bb7e961f65712443277719/latest/_static/js/iframeResizer.contentWindow.min.js"></script><meta http-equiv="Content-Type" content="text/html; charset=utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge,IE=9,chrome=1"><meta name="generator" content="MATLAB 2021a"><title>Extraction of a submap from a Cell Designer map (PART 3) </title><style type="text/css">.rtcContent { padding: 30px; } .S0 { margin: 3px 10px 5px 4px; padding: 0px; line-height: 28.8px; min-height: 0px; white-space: normal; color: rgb(213, 80, 0); font-family: Helvetica, Arial, sans-serif; font-style: normal; font-size: 24px; font-weight: normal; text-align: left;  }
.S1 { margin: 20px 10px 5px 4px; padding: 0px; line-height: 20px; min-height: 0px; white-space: normal; color: rgb(60, 60, 60); font-family: Helvetica, Arial, sans-serif; font-style: normal; font-size: 20px; font-weight: bold; text-align: left;  }
.S2 { margin: 3px 10px 5px 4px; padding: 0px; line-height: 20px; min-height: 0px; white-space: normal; color: rgb(60, 60, 60); font-family: Helvetica, Arial, sans-serif; font-style: normal; font-size: 20px; font-weight: bold; text-align: left;  }
.S3 { margin: 2px 10px 9px 4px; padding: 0px; line-height: 21px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Helvetica, Arial, sans-serif; font-style: normal; font-size: 14px; font-weight: normal; text-align: left;  }
.CodeBlock { background-color: #F7F7F7; margin: 10px 0 10px 0;}
.S4 { border-left: 1px solid rgb(233, 233, 233); border-right: 1px solid rgb(233, 233, 233); border-top: 1px solid rgb(233, 233, 233); border-bottom: 1px solid rgb(233, 233, 233); border-radius: 4px 4px 0px 0px; padding: 6px 45px 4px 13px; line-height: 17.234px; min-height: 18px; white-space: nowrap; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px;  }
.S5 { color: rgb(64, 64, 64); padding: 10px 0px 6px 17px; background: rgb(255, 255, 255) none repeat scroll 0% 0% / auto padding-box border-box; font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px; overflow-x: hidden; line-height: 17.234px;  }
/* Styling that is common to warnings and errors is in diagnosticOutput.css */.embeddedOutputsErrorElement {    min-height: 18px;    max-height: 250px;    overflow: auto;}
.embeddedOutputsErrorElement.inlineElement {}
.embeddedOutputsErrorElement.rightPaneElement {}
/* Styling that is common to warnings and errors is in diagnosticOutput.css */.embeddedOutputsWarningElement{    min-height: 18px;    max-height: 250px;    overflow: auto;}
.embeddedOutputsWarningElement.inlineElement {}
.embeddedOutputsWarningElement.rightPaneElement {}
/* Copyright 2015-2019 The MathWorks, Inc. *//* In this file, styles are not scoped to rtcContainer since they could be in the Dojo Tooltip */.diagnosticMessage-wrapper {    font-family: Menlo, Monaco, Consolas, "Courier New", monospace;    font-size: 12px;}
.diagnosticMessage-wrapper.diagnosticMessage-warningType {    color: rgb(255,100,0);}
.diagnosticMessage-wrapper.diagnosticMessage-warningType a {    color: rgb(255,100,0);    text-decoration: underline;}
.diagnosticMessage-wrapper.diagnosticMessage-errorType {    color: rgb(230,0,0);}
.diagnosticMessage-wrapper.diagnosticMessage-errorType a {    color: rgb(230,0,0);    text-decoration: underline;}
.diagnosticMessage-wrapper .diagnosticMessage-messagePart,.diagnosticMessage-wrapper .diagnosticMessage-causePart {    white-space: normal;}
.diagnosticMessage-wrapper .diagnosticMessage-stackPart {    white-space: normal;}
.embeddedOutputsTextElement,.embeddedOutputsVariableStringElement {    white-space: normal;    word-wrap:  initial;    min-height: 18px;    max-height: 250px;    overflow: auto;}
.textElement,.rtcDataTipElement .textElement {    padding-top: 3px;}
.embeddedOutputsTextElement.inlineElement,.embeddedOutputsVariableStringElement.inlineElement {}
.inlineElement .textElement {}
.embeddedOutputsTextElement.rightPaneElement,.embeddedOutputsVariableStringElement.rightPaneElement {    min-height: 16px;}
.rightPaneElement .textElement {    padding-top: 2px;    padding-left: 9px;}
.S6 { border-left: 1px solid rgb(233, 233, 233); border-right: 1px solid rgb(233, 233, 233); border-top: 1px solid rgb(233, 233, 233); border-bottom: 0px none rgb(0, 0, 0); border-radius: 4px 4px 0px 0px; padding: 6px 45px 0px 13px; line-height: 17.234px; min-height: 18px; white-space: nowrap; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px;  }
.S7 { border-left: 1px solid rgb(233, 233, 233); border-right: 1px solid rgb(233, 233, 233); border-top: 0px none rgb(0, 0, 0); border-bottom: 0px none rgb(0, 0, 0); border-radius: 0px; padding: 0px 45px 0px 13px; line-height: 17.234px; min-height: 18px; white-space: nowrap; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px;  }
.S8 { border-left: 1px solid rgb(233, 233, 233); border-right: 1px solid rgb(233, 233, 233); border-top: 0px none rgb(0, 0, 0); border-bottom: 1px solid rgb(233, 233, 233); border-radius: 0px; padding: 0px 45px 4px 13px; line-height: 17.234px; min-height: 18px; white-space: nowrap; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px;  }
.S9 { margin: 10px 10px 9px 4px; padding: 0px; line-height: 21px; min-height: 0px; white-space: normal; color: rgb(0, 0, 0); font-family: Helvetica, Arial, sans-serif; font-style: normal; font-size: 14px; font-weight: normal; text-align: left;  }
.S10 { margin: 15px 10px 5px 4px; padding: 0px; line-height: 18px; min-height: 0px; white-space: normal; color: rgb(60, 60, 60); font-family: Helvetica, Arial, sans-serif; font-style: normal; font-size: 17px; font-weight: bold; text-align: left;  }
.S11 { border-left: 1px solid rgb(233, 233, 233); border-right: 1px solid rgb(233, 233, 233); border-top: 1px solid rgb(233, 233, 233); border-bottom: 1px solid rgb(233, 233, 233); border-radius: 0px; padding: 6px 45px 4px 13px; line-height: 17.234px; min-height: 18px; white-space: nowrap; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px;  }
.S12 { border-left: 1px solid rgb(233, 233, 233); border-right: 1px solid rgb(233, 233, 233); border-top: 1px solid rgb(233, 233, 233); border-bottom: 0px none rgb(0, 0, 0); border-radius: 0px; padding: 6px 45px 0px 13px; line-height: 17.234px; min-height: 18px; white-space: nowrap; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px;  }
.S13 { border-left: 1px solid rgb(233, 233, 233); border-right: 1px solid rgb(233, 233, 233); border-top: 0px none rgb(0, 0, 0); border-bottom: 1px solid rgb(233, 233, 233); border-radius: 0px 0px 4px 4px; padding: 0px 45px 4px 13px; line-height: 17.234px; min-height: 18px; white-space: nowrap; color: rgb(0, 0, 0); font-family: Menlo, Monaco, Consolas, "Courier New", monospace; font-size: 14px;  }</style></head><body><div class = rtcContent><h1  class = 'S0'><span style=' font-weight: bold;'>Extraction of a submap from a Cell Designer map (PART 3) </span></h1><h2  class = 'S1'><span>Authors: Ronan M.T. Fleming, Leiden University</span></h2><h2  class = 'S1'><span style=' font-weight: bold;'>Reviewer(s): </span></h2><h2  class = 'S2'><span>INTRODUCTION</span></h2><div  class = 'S3'><span>Given a generic map of metabolism, creat a derivative map by removing a subset of the reactions.</span></div><h2  class = 'S1'><span>EQUIPMENT SETUP </span></h2><div  class = 'S3'><span>To visualise the metabolic maps it is necessary to obtain the version 4.4 of CellDesigner. This software can be freely downloaded from: </span></div><div  class = 'S3'><a href = "http://www.celldesigner.org/download.html"><span>http://www.celldesigner.org/download.html</span></a></div><h2  class = 'S2'><span>PROCEDURE</span></h2><h2  class = 'S1'><span>1. Import a CellDesigner XML file to MATLAB environment</span></h2><div  class = 'S3'><span>The </span><span style=' font-family: monospace;'>transformXML2Map</span><span> function parses an XML file from Cell Designer (CD) into a Matlab structure. This structure is organised similarly to the structure found in the COnstraint-Base and Reconstruction Analysis (COBRA) models.</span></div><div  class = 'S3'><span>Read in a map</span></div><div class="CodeBlock"><div class="inlineWrapper outputs"><div  class = 'S4'><span style="white-space: normal"><span >[GlyXml, GlyMap] = transformXML2Map(</span><span style="color: rgb(170, 4, 249);">'glycolysisAndTCA.xml'</span><span >);</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsTextElement" uid="E2ADCF4E" data-testid="output_0" data-width="428" data-height="18" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">Elapsed time is 1.834226 seconds.</div></div></div></div></div><h2  class = 'S1'><span>2. Remove some reactions from the map</span></h2><div class="CodeBlock"><div class="inlineWrapper"><div  class = 'S6'><span style="white-space: normal"><span style="color: rgb(14, 0, 255);">if </span><span >1</span></span></div></div><div class="inlineWrapper"><div  class = 'S7'><span style="white-space: normal"><span >    rxnRemoveList={</span><span style="color: rgb(170, 4, 249);">'ENO'</span><span >;</span><span style="color: rgb(170, 4, 249);">'PFK'</span><span >;</span><span style="color: rgb(170, 4, 249);">'PGMT'</span><span >;</span><span style="color: rgb(170, 4, 249);">'ABC'</span><span >};</span></span></div></div><div class="inlineWrapper"><div  class = 'S7'><span style="white-space: normal"><span style="color: rgb(14, 0, 255);">else</span></span></div></div><div class="inlineWrapper"><div  class = 'S7'><span style="white-space: normal"><span >    rxnRemoveList={</span><span style="color: rgb(170, 4, 249);">'PGMT'</span><span >};</span></span></div></div><div class="inlineWrapper"><div  class = 'S7'><span style="white-space: normal"><span style="color: rgb(14, 0, 255);">end</span></span></div></div><div class="inlineWrapper"><div  class = 'S7'><span style="white-space: normal"><span >printLevel=1;</span></span></div></div><div class="inlineWrapper outputs"><div  class = 'S8'><span style="white-space: normal"><span >[GlyXmlStructSubset,GlyMapSubset,rxnNotInMap] = removeMapReactions(GlyXml,GlyMap,rxnRemoveList,printLevel);</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsTextElement" uid="2A276DA3" data-testid="output_1" data-width="428" data-height="18" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">ABC not present in the map</div></div></div></div></div><div  class = 'S9'><span>There is no reaction 'ABC' in the map, so the function alerts that it has not been removed. </span></div><div class="CodeBlock"><div class="inlineWrapper outputs"><div  class = 'S4'><span style="white-space: normal"><span >rxnRemoveList(rxnNotInMap)</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement" uid="097B8BB5" data-testid="output_2" data-width="428" data-height="34" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">ans = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">1×1 cell array</span></span>
    {'ABC'}</div></div></div></div></div></div><h2  class = 'S1'><span>3. Export the modified map</span></h2><div class="CodeBlock"><div class="inlineWrapper outputs"><div  class = 'S4'><span style="white-space: normal"><span >transformMap2XML(GlyXmlStructSubset,GlyMapSubset,</span><span style="color: rgb(170, 4, 249);">'glycolysisAndTCA_subset.xml'</span><span >);</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsTextElement" uid="F5B5D3B8" data-testid="output_3" data-width="428" data-height="18" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">Elapsed time is 1.317182 seconds.</div></div></div></div></div><h3  class = 'S10'><span>4. Import the modified map and compare it with the matlab structures</span></h3><div class="CodeBlock"><div class="inlineWrapper outputs"><div  class = 'S4'><span style="white-space: normal"><span >[GlyXmlStructSubset2,GlyMapSubset2] = transformXML2Map(</span><span style="color: rgb(170, 4, 249);">'glycolysisAndTCA_subset.xml'</span><span >);</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsTextElement" uid="567CC9B5" data-testid="output_4" data-width="428" data-height="18" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">Elapsed time is 1.667602 seconds.</div></div><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement" uid="096A1D5E" data-testid="output_5" data-width="428" data-height="62" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">ans = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">struct with fields:</span></span></div><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">        id: 're2'
    metaid: 're57'
      name: 'DPGM'</div></div></div><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement" uid="F14E4243" data-testid="output_6" data-width="428" data-height="76" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">ans = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">struct with fields:</span></span></div><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">            id: 're2'
        metaid: 're57'
          name: 'DPGM'
    reversible: 'true'</div></div></div></div></div></div><div  class = 'S3'><span>Compare xml structure</span></div><div class="CodeBlock"><div class="inlineWrapper outputs"><div  class = 'S4'><span style="white-space: normal"><span >[resultXml, whyXml] = structeq(GlyXmlStructSubset, GlyXmlStructSubset2)</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement" uid="C92EA43B" data-testid="output_7" data-width="428" data-height="34" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">resultXml = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">logical</span></span>
   0</div></div></div><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement scrollableOutput" uid="2CEB4043" data-testid="output_8" data-width="428" data-height="48" data-hashorizontaloverflow="true" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">whyXml = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">struct with fields:</span></span></div><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">    Reason: 'Properties are different &lt;- Unequal Subcell &lt;- Properties are different &lt;- Unequal Subcell &lt;- Properties are different &lt;- Unequal Subcell &lt;- Properties are different &lt;- Unequal Subcell &lt;- Unequal Subcell &lt;- Properties are different &lt;- Unequal Subcell &lt;- Number of fields are different'
     Where: '(1).sbml(1).model(1).listOfReactions(1).reaction{2}(1).Attributes'</div></div></div></div></div><div class="inlineWrapper outputs"><div  class = 'S11'><span style="white-space: normal"><span >GlyXmlStructSubset.sbml(1).model(1).listOfReactions(1).reaction{2}(1).Attributes</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement" uid="FFC80B9D" data-testid="output_9" data-width="428" data-height="62" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">ans = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">struct with fields:</span></span></div><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">        id: 're2'
    metaid: 're57'
      name: 'DPGM'</div></div></div></div></div><div class="inlineWrapper outputs"><div  class = 'S11'><span style="white-space: normal"><span >GlyXmlStructSubset2.sbml(1).model(1).listOfReactions(1).reaction{2}(1).Attributes</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement" uid="A58AD55B" data-testid="output_10" data-width="428" data-height="76" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">ans = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">struct with fields:</span></span></div><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">            id: 're2'
        metaid: 're57'
          name: 'DPGM'
    reversible: 'true'</div></div></div></div></div></div><div  class = 'S9'><span>Compare map structure</span></div><div class="CodeBlock"><div class="inlineWrapper outputs"><div  class = 'S4'><span style="white-space: normal"><span >[resultMap, whyMap] = structeq(GlyMapSubset, GlyMapSubset2)</span></span></div><div  class = 'S5'><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement" uid="31E5391B" data-testid="output_11" data-width="428" data-height="34" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">resultMap = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">logical</span></span>
   1</div></div></div><div class="inlineElement eoOutputWrapper embeddedOutputsVariableStringElement" uid="B83D6850" data-testid="output_12" data-width="428" data-height="48" data-hashorizontaloverflow="false" style="width: 458px; max-height: 261px; white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div class="textElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;"><span class="variableNameElement" style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">whyMap = <span class="headerElement" style="white-space: normal; font-style: italic; color: rgb(179, 179, 179); font-size: 12px;">struct with fields:</span></span></div><div style="white-space: normal; font-style: normal; color: rgb(64, 64, 64); font-size: 12px;">    Reason: ''
     Where: ''</div></div></div></div></div><div class="inlineWrapper"><div  class = 'S12'></div></div><div class="inlineWrapper"><div  class = 'S13'><span style="white-space: normal"><span style="color: rgb(14, 0, 255);">return</span></span></div></div></div><h2  class = 'S2'><span>4. Remove reactions from the map directly</span></h2><div class="CodeBlock"><div class="inlineWrapper"><div  class = 'S6'><span style="white-space: normal"><span >fileName = </span><span style="color: rgb(170, 4, 249);">'glycolysisAndTCA.xml'</span><span >;</span></span></div></div><div class="inlineWrapper"><div  class = 'S7'><span style="white-space: normal"><span >printLevel=1;</span></span></div></div><div class="inlineWrapper"><div  class = 'S13'><span style="white-space: normal"><span >removeCDReactions(fileName,rxnRemoveList,printLevel)</span></span></div></div></div><div  class = 'S9'><span></span></div><div  class = 'S3'></div>
<br>
<!-- 
##### SOURCE BEGIN #####
%% *Extraction of a submap from a Cell Designer map (PART 3)* 
%% Authors: Ronan M.T. Fleming, Leiden University
%% *Reviewer(s):* 
%% INTRODUCTION
% Given a generic map of metabolism, creat a derivative map by removing a subset 
% of the reactions.
%% EQUIPMENT SETUP 
% To visualise the metabolic maps it is necessary to obtain the version 4.4 
% of CellDesigner. This software can be freely downloaded from: 
% 
% <http://www.celldesigner.org/download.html http://www.celldesigner.org/download.html>
%% PROCEDURE
%% 1. Import a CellDesigner XML file to MATLAB environment
% The |transformXML2Map| function parses an XML file from Cell Designer (CD) 
% into a Matlab structure. This structure is organised similarly to the structure 
% found in the COnstraint-Base and Reconstruction Analysis (COBRA) models.
% 
% Read in a map

[GlyXml, GlyMap] = transformXML2Map('glycolysisAndTCA.xml');
%% 2. Remove some reactions from the map

if 1
    rxnRemoveList={'ENO';'PFK';'PGMT';'ABC'};
else
    rxnRemoveList={'PGMT'};
end
printLevel=1;
[GlyXmlStructSubset,GlyMapSubset,rxnNotInMap] = removeMapReactions(GlyXml,GlyMap,rxnRemoveList,printLevel);
%% 
% There is no reaction 'ABC' in the map, so the function alerts that it has 
% not been removed. 

rxnRemoveList(rxnNotInMap)
%% 3. Export the modified map

transformMap2XML(GlyXmlStructSubset,GlyMapSubset,'glycolysisAndTCA_subset.xml');
% 4. Import the modified map and compare it with the matlab structures

[GlyXmlStructSubset2,GlyMapSubset2] = transformXML2Map('glycolysisAndTCA_subset.xml');
%% 
% Compare xml structure

[resultXml, whyXml] = structeq(GlyXmlStructSubset, GlyXmlStructSubset2)
GlyXmlStructSubset.sbml(1).model(1).listOfReactions(1).reaction{2}(1).Attributes
GlyXmlStructSubset2.sbml(1).model(1).listOfReactions(1).reaction{2}(1).Attributes
%% 
% Compare map structure

[resultMap, whyMap] = structeq(GlyMapSubset, GlyMapSubset2)

return
%% 4. Remove reactions from the map directly

fileName = 'glycolysisAndTCA.xml';
printLevel=1;
removeCDReactions(fileName,rxnRemoveList,printLevel)
%% 
% 
% 
%
##### SOURCE END #####
-->
</div></body></html>